﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace _uitwerking__Algoritmiek
{
    public class code_GGD1
    {
        public int bewerkingen;

        public code_GGD1()
        {
            bewerkingen = 0;
        }
        
        public int execute(int M, int N)
        {
            int T = M - N;
            
            while (M % T != 0 || N % T != 0)
            {
                T = T - 1;
                bewerkingen++;
            } return T;
        }
    }
}
